package com.yingside.collection.stack;

public interface IStack<E> {
    //入栈
    void push(E e) throws MyStackException;
    //出栈
    E pop();
    //是否空栈
    boolean isEmpty();
    //是否满栈
    boolean isMax();

    //显示打印
    void display();
    //获取栈当前长度
    int size();

    //取得顶栈
    E peek();
    //根据下标获取对应的值
    E indexOf(int index);

}
